Return to start page

Core/General/Struct Slk Table Entry.j

Code

		
1			/// Do not use this library, it is unfinished!
2 /// @todo Finish and test this library.
3 library AStructCoreGeneralSlkTableEntry
4
5 /// This struct is a basic inheritance struct for SLK tables.
6 /// SLK tables are used by Warcraft 3 for saving object data of various kinds of objects like doodads, units etc..
7 /// @todo There exists a problem with strings because their quotes will be ignored.
8 struct ASlkTableEntry
9 private static thistype array m_entry
10
11 /// This method is based on the JassHelper manual's example.
12 public static method entry takes integer index returns thistype
13 if (thistype.m_entry[index] == 0) then
14 set thistype.m_entry[index] = thistype.create()
15 endif
16 return thistype.m_entry[index]
17 endmethod
18 endstruct
19
20 endlibrary